from launch import LaunchDescription
from launch_ros.actions import Node
#节点重名
# def generate_launch_description():
#     return LaunchDescription([
#         Node(package="turtlesim",executable="turtlesim_node",name="turtle1"),
#         Node(package="turtlesim",executable="turtlesim_node",namespace="t1"),
#         Node(package="turtlesim",executable="turtlesim_node",namespace="t1",name="t1")
#     ]) 
#话题重名
def generate_launch_description():
    return LaunchDescription([
        Node(package="turtlesim",executable="turtlesim_node",namespace="t1"),
        Node(package="turtlesim",executable="turtlesim_node",
             remappings=[("/turtle1/cmd_vel","cmd_vel")]
        )
    
    ]) 